import request from '@/utils/request'
// 分页查询仓库
export const CangkuList = (params) => {
  return request({
    url: '/api/warehouse/page',
    method: 'GET',
    params
  })
}
// 新增仓库
export const AddList = (data) => {
  return request({
    url: '/api/warehouse',
    method: 'POST',
    data
  })
}
// 查询仓库
export const BianJiList = (id) => {
  return request({
    url: `api/warehouse/${id}`

  })
}
// 编辑仓库
export const BianJi = (data) => {
  return request({
    url: 'api/warehouse',
    method: 'PUT',
    data
  })
}
// 删除仓库
export const ShanChu = (id) => {
  return request({
    url: `api/warehouse?ids[]=${id}`,
    method: 'DELETE'
  })
}
// 全部仓库
export const QuanBuList = () => {
  return request({
    url: 'api/warehouse/list'
  })
}
